<?php

namespace App\Livewire;

use App\Models\Post;
use Illuminate\Support\Facades\Auth;
use Livewire\Component;

class Share extends Component
{
    public function render()
    {
        $post = Post::query()->withoutGlobalScopes()->find(1);

        $code = Auth::user()->share?->code;

        return view('livewire.share', compact('post', 'code'));
    }
}
